home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PsL Monthly 1993 December
/
PSL Monthly Shareware CD-ROM (December 1993).iso
/
prgmming
/
dos
/
pascal
/
mathlib.exe
/
SAVAGE.PAS
< prev
Wrap
Pascal/Delphi Source File
|
1991-11-30
|
1KB
|
31 lines
{$N+}
PROGRAM Savage;
{ variation of the savage benchmark for floating point performance }
USES DOS, MathLib;
CONST isize = 25000;
VAR hr1,min1,sec1,hun1,hr2,min2,sec2,hun2:WORD;
i,j: INTEGER;
time: REAL;
a: DOUBLE;
BEGIN
a := 1.0;
GetTime(hr1,min1,sec1,hun1);
FOR j := 1 TO 15 DO FOR i := 1 TO isize DO
a := TAN(ARCTAN(EXP(LN(SQRT(a*a)))))+1;
GetTime(hr2,min2,sec2,hun2);
time := 3600*(hr2-hr1)+60*(min2-min1)+(sec2-sec1-1)+(100+hun2-hun1)/100;
WRITELN('time (sec): ',time:6:2);
WRITELN('result "a": ',a);
END.
{ Results with Club American 486/33 (time in seconds):
OperatingSys MathLib P287MathLib P387MathLib
------------ -------- ----------- -----------
MS-DOS 5 36.20 22.85 19.88
w/ 386MAX 6 47.79 22.91 19.88
w/ NetRoom 2 52.01 22.90 19.88
w/ HIMEM/EMM 57.51 23.01 19.99
}